package dkbta.ontology;

import dkbta.ontology.loading.OntologyException;

/**
 * An interface to be implemented by objects that require validation after the entire
 * ontology has been parsed.<br>
 * <br>
 * For example this is the case of contexts that can be induced by states but states are
 * parsed after contexts. So we first parse everything and then check all the connections
 * between all objects
 * 
 * @author Uri Kanonov
 */
public interface Validatable{
	/**
	 * Checks that the ontology-related-object is valid. <br>
	 * <b>Important:</b> In this method each element definition should add all of it's prerequisite elements using <tt>addPrerequisiteElement</tt>
	 * 
	 * @param ontology The completely loaded ontology
	 * @throws OntologyException If the object is invalid
	 * 
	 */
	public void validate(Ontology ontology) throws OntologyException;
}
